package com.domor.xxx.common.exception;

/**
 * <h3>用户信息异常类</h3>
 * @author liyuyang
 * @date 2020/5/15
 */
public class UserException extends RuntimeException {

    public static final String NOT_NULL = "用户名和密码不能为空";
    public static final String NOT_EXIST = "用户名不存在";
    public static final String PWD_ERROR = "密码错误";
    public static final String USER_DELETE = "对不起，您的账号已被删除";
    public static final String USER_BLOCKED = "用户已封禁，请联系管理员";
    public static final String ROLE_BLOCKED = "角色已封禁，请联系管理员";
    public static final String RETRY_LIMIT_COUNT = "密码输入错误 {} 次";
    public static final String RETRY_LIMIT_EXCEED = "密码输入错误 {} 次，帐户锁定10分钟";

    private String message;

    public UserException(String message) {
        this.message = message;
    }

    @Override
    public String getMessage(){
        return this.message;
    }

}
